
<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ include file="/base/base.jsp" %>
<%@ include file="/base/database.jsp" %>

<%
  
       request.setCharacterEncoding("utf-8");

      String loginNo =request.getParameter("loginNo");
      String password  =request.getParameter("password");

   StringBuffer sqlBuff=new StringBuffer();
   sqlBuff.append("update sys_studentlogin set loginNo=?,password=?");   

   String sql=sqlBuff.toString();

   Connection conn=getConn();

    PreparedStatement pstmt=conn.prepareStatement(sql);
  
       int parameterIndex=1;
       
       pstmt.setString(parameterIndex++, loginNo);
       pstmt.setString(parameterIndex++, password);

  
       int c=pstmt.executeUpdate();
  
       if(pstmt!=null){
         pstmt.close();
        }
       if(conn!=null){
         conn.close();
        }
       
	response.sendRedirect("student_editlogin.jsp");

   
%>